// pages/success/success.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    type: '',
  },
  /**
   * 返回兑换页面
   */
  confirm: function(e) {
    switch (this.data.type) {
      case 'help':
        wx.redirectTo({
          url: '/pages/culture/cultureList/cultureList'
        });
        break;
      case 'store':
        wx.redirectTo({
          url: '/pages/store/store'
        });
        break;
    }
  },
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function(options) {
    let type = options.type;
    console.log('type', type)
    this.setData({
      type: type
    })
  },
})